<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:ui="http://xmlns.jcp.org/jsf/facelets"
      xmlns:h="http://xmlns.jcp.org/jsf/html"
      xmlns:f="http://xmlns.jcp.org/jsf/core"
      xmlns:p="http://primefaces.org/ui">

    <ui:composition>

        <p:dialog id="DocumentoFiscalEditDlg" widgetVar="DocumentoFiscalEditDialog" modal="true" resizable="false" appendTo="@(body)" header="#{bundle.EditDocumentoFiscalTitle}">
            <h:form id="DocumentoFiscalEditForm">
                <h:panelGroup id="display">
                    <p:panelGrid columns="2" rendered="#{documentoFiscalController.selected != null}">
                        <p:outputLabel value="#{bundle.EditDocumentoFiscalLabel_idDocumentoFiscal}" for="idDocumentoFiscal" />
                        <p:inputText id="idDocumentoFiscal" value="#{documentoFiscalController.selected.idDocumentoFiscal}" title="#{bundle.EditDocumentoFiscalTitle_idDocumentoFiscal}" required="true" requiredMessage="#{bundle.EditDocumentoFiscalRequiredMessage_idDocumentoFiscal}"/>
                        <p:outputLabel value="#{bundle.EditDocumentoFiscalLabel_nuDanfe}" for="nuDanfe" />
                        <p:inputText id="nuDanfe" value="#{documentoFiscalController.selected.nuDanfe}" title="#{bundle.EditDocumentoFiscalTitle_nuDanfe}" required="true" requiredMessage="#{bundle.EditDocumentoFiscalRequiredMessage_nuDanfe}"/>
                        <p:outputLabel value="#{bundle.EditDocumentoFiscalLabel_vlNfeBruto}" for="vlNfeBruto" />
                        <p:inputText id="vlNfeBruto" value="#{documentoFiscalController.selected.vlNfeBruto}" title="#{bundle.EditDocumentoFiscalTitle_vlNfeBruto}" required="true" requiredMessage="#{bundle.EditDocumentoFiscalRequiredMessage_vlNfeBruto}"/>
                        <p:outputLabel value="#{bundle.EditDocumentoFiscalLabel_vlNfeLiquido}" for="vlNfeLiquido" />
                        <p:inputText id="vlNfeLiquido" value="#{documentoFiscalController.selected.vlNfeLiquido}" title="#{bundle.EditDocumentoFiscalTitle_vlNfeLiquido}" required="true" requiredMessage="#{bundle.EditDocumentoFiscalRequiredMessage_vlNfeLiquido}"/>
                        <p:outputLabel value="#{bundle.EditDocumentoFiscalLabel_vlIcms}" for="vlIcms" />
                        <p:inputText id="vlIcms" value="#{documentoFiscalController.selected.vlIcms}" title="#{bundle.EditDocumentoFiscalTitle_vlIcms}" />
                        <p:outputLabel value="#{bundle.EditDocumentoFiscalLabel_vlDesconto}" for="vlDesconto" />
                        <p:inputText id="vlDesconto" value="#{documentoFiscalController.selected.vlDesconto}" title="#{bundle.EditDocumentoFiscalTitle_vlDesconto}" />
                        <p:outputLabel value="#{bundle.EditDocumentoFiscalLabel_dtNfe}" for="dtNfe" />
                        <p:calendar id="dtNfe" pattern="MM/dd/yyyy" value="#{documentoFiscalController.selected.dtNfe}" title="#{bundle.EditDocumentoFiscalTitle_dtNfe}" required="true" requiredMessage="#{bundle.EditDocumentoFiscalRequiredMessage_dtNfe}" showOn="button"/>
                        <p:outputLabel value="#{bundle.EditDocumentoFiscalLabel_dtRecebimento}" for="dtRecebimento" />
                        <p:calendar id="dtRecebimento" pattern="MM/dd/yyyy" value="#{documentoFiscalController.selected.dtRecebimento}" title="#{bundle.EditDocumentoFiscalTitle_dtRecebimento}" required="true" requiredMessage="#{bundle.EditDocumentoFiscalRequiredMessage_dtRecebimento}" showOn="button"/>
                    </p:panelGrid>
                    <p:commandButton actionListener="#{documentoFiscalController.update}" value="#{bundle.Save}" update="display,:DocumentoFiscalListForm:datalist,:growl" oncomplete="handleSubmit(args, 'DocumentoFiscalEditDialog');"/>
                    <p:commandButton value="#{bundle.Cancel}" onclick="DocumentoFiscalEditDialog.hide()"/>
                </h:panelGroup>
            </h:form>
        </p:dialog>

    </ui:composition>
</html>
